
package com.sword.common.utils;

import java.time.LocalDateTime;
import java.time.temporal.*;
public class LocalDateTimeUtil {


    public static LocalDateTime offset(LocalDateTime time, long number, TemporalUnit field) {
        return (LocalDateTime)offset(time, number, field);
    }
    public static <T extends Temporal> T offset(T time, long number, TemporalUnit field) {
        return null == time ? null : (T) time.plus(number, field);
    }
}
